package com.bishe.app.modules.groupuser.service.impl;

import com.bishe.app.core.enums.IsDel;
import com.bishe.app.modules.groupuser.entity.GroupUser;
import com.bishe.app.modules.groupuser.mapper.GroupUserMapper;
import com.bishe.app.modules.groupuser.service.GroupUserService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 组织-用户表 服务实现类
 * </p>
 *
 * @author 
 * @since 2024-03-13
 */
@Service
public class GroupUserServiceImpl extends ServiceImpl<GroupUserMapper, GroupUser> implements GroupUserService {

    public GroupUser listNonDel(Long groupId,Long userId){
        return lambdaQuery()
                .eq(GroupUser::getGroupId,groupId)
                .eq(GroupUser::getUserId,userId)
                .eq(GroupUser::getIsDel,IsDel.N.getCode())
                .one();
    }

}
